Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: define auxiliary functions for the batching of sumcheck claims (Arecibo backport) #273

Merged
merged 2 commits into from
Nov 29, 2023

Conversation

huitseeker
Copy link
Contributor

@huitseeker huitseeker commented Nov 29, 2023

This backports the following Arecibo PRs:

This factors out the single-point aggregation of Sumcheck instances implemented at the end of the (non-preprocessing) Spartan SNARk to a couple of auxiliary functions batch_eval_prove/batch_eval_verify.

  • They will be reused in our upcoming instance of Supernova, so we could include the change here or there,
  • but It's expected this simple change will also ease review and testing of that part of the protocol in the future.

This also performs minor changes the API of a few internal functions which took their argument by value without needing to (as indicated by tooling).

adr1anh and others added 2 commits November 29, 2023 12:06
…rosoft#122)

* refactor: Remove nedless pass-by-value instances, turn on the corresponding clippy lint

- Updated function parameters in `ppsnark.rs` and `snark.rs` from `Vec<G::Scalar>` to `&[G::Scalar]` (introduced in microsoft#106),
- Modified the `prove` function in `ppsnark.rs` to also convert `T_row`, `W_row`, `T_col`, and `W_col` from `Vec` to slices (`&[G::Scalar]`).
- Enhanced the `xclippy` alias in `.cargo/config` by adding `-Wclippy::checked_conversions`, `-Wclippy::needless_pass_by_value`, and `-Wclippy::unnecessary_mut_passed` and reorganizing its elements.

* `PolyEval{Instance, Witness}::pad`
Accept `Vec` rather that `&[T]` to avoid copies

Co-authored-by: Francois Garillot <[email protected]>

---------

Co-authored-by: Adrian Hamelink <[email protected]>
@srinathsetty srinathsetty merged commit 9004d70 into microsoft:main Nov 29, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants